Ext.define('DCApp.view.figure.List', {
    extend: 'Ext.grid.Panel',
    alias: 'widget.figurelist',
    
    requires: [
        'DCApp.controller.ListController',
        'DCApp.view.figure.ListModel',
        'DCApp.view.GridFilters'
    ],

    controller: 'list',
    plugins: ['gfilters'],
    viewModel: {
        type: 'figurelist'
    },
    bind: {
        store: '{objs}'
    },
    header:false,

    selType: 'checkboxmodel',
    
    tbar: ['->',{
        text: '录入',
        handler: 'onNew'
    }],
    
	
	listeners: {
        itemdblclick: 'onDblClick'
    },
    
    columns: [
            {
                text     : '编号',
                dataIndex: 'objId',
                filter: 'number'
            },
            {
                text     : '姓名',
                dataIndex: 'name',
                filter: 'string'
            },
            {
                text     : '分类',
                dataIndex: 'className',
                filter: 'string'
            },
            {
                text     : '撰稿人',
                dataIndex: 'author',
                filter: 'string'
            },
            {
                text     : '更新时间',
                dataIndex: 'lastUpdate',
                xtype: 'datecolumn',
                filter: true
            }
        ],
    initComponent: function(){
    	this.callParent();
    }
 });
